

#ifndef _XPLEX_H_
#define _XPLEX_H_

struct CXPlex     // warning variable length structure
{
	CXPlex* pNext;
	DWORD dwReserved[1];    // align on 8 byte boundary
	
	// BYTE data[maxNum*elementSize];

	void* data() { return this+1; }

	static CXPlex* PASCAL Create(CXPlex*& head, UINT nMax, UINT cbElement);
			// like 'calloc' but no zero fill
			// may throw memory exceptions

	void FreeDataChain();       // free this one and links
};


#endif // _XPLEX_H_